package com.rds.workflow.service.impl;

import com.rds.common.utils.DateUtils;
import com.rds.workflow.domain.RdaWorkflowDynamicattribute;
import com.rds.workflow.mapper.RdaWorkflowDynamicattributeMapper;
import com.rds.workflow.service.IRdaWorkflowDynamicattributeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class RdaWorkflowDynamicattributeServiceImpl implements IRdaWorkflowDynamicattributeService {

    @Autowired
    private RdaWorkflowDynamicattributeMapper rdaWorkflowDynamicattributeMapper;

    @Override
    public RdaWorkflowDynamicattribute selectRdaWorkflowDynamicattributeById(Long id) {
        return rdaWorkflowDynamicattributeMapper.selectRdaWorkflowDynamicattributeById(id);
    }

    @Override
    public List<RdaWorkflowDynamicattribute> selectRdaWorkflowDynamicattributeList(RdaWorkflowDynamicattribute rdaWorkflowDynamicattribute) {
        return rdaWorkflowDynamicattributeMapper.selectRdaWorkflowDynamicattributeList(rdaWorkflowDynamicattribute);
    }

    @Override
    public int insertRdaWorkflowDynamicattribute(RdaWorkflowDynamicattribute rdaWorkflowDynamicattribute) {
        rdaWorkflowDynamicattribute.setCreateTime(DateUtils.getNowDate());
        return rdaWorkflowDynamicattributeMapper.insertRdaWorkflowDynamicattribute(rdaWorkflowDynamicattribute);
    }

    @Override
    public int updateRdaWorkflowDynamicattribute(RdaWorkflowDynamicattribute rdaWorkflowDynamicattribute) {
        rdaWorkflowDynamicattribute.setModifyTime(DateUtils.getNowDate());
        return rdaWorkflowDynamicattributeMapper.updateRdaWorkflowDynamicattribute(rdaWorkflowDynamicattribute);
    }

    @Override
    public int deleteRdaWorkflowDynamicattributeByIds(Long[] ids) {
        return rdaWorkflowDynamicattributeMapper.deleteRdaWorkflowDynamicattributeByIds(ids);
    }
}
